package com.webchat.domain.dto.queue;


import com.webchat.domain.dto.payment.PaymentResultDTO;
import lombok.Data;

@Data
public class PaymentCallBackQueueDTO extends BaseDelayQueueDTO {

    /**
     * 支付结果回调业务参数
     *
     */
    private PaymentResultDTO data;


    public static PaymentCallBackQueueDTO of(String taskId,
                                      PaymentResultDTO data,
                                      int retryTimes,
                                      Long time) {
        PaymentCallBackQueueDTO queueDTO = new PaymentCallBackQueueDTO();
        queueDTO.setData(data);
        queueDTO.setTaskId(taskId);
        queueDTO.setTime(time);
        queueDTO.setRetryTimes(retryTimes);
        return queueDTO;
    }
}
